package com.thprojects.myphotomemories.model;

import android.os.Parcel;
import android.os.Parcelable;

public class Contact implements Parcelable{

	String mDisplayName;
	String mLookupKey;

	
	public Contact(String displayName, String lookupKey) {
		super();
		this.mDisplayName = displayName;
		this.mLookupKey = lookupKey;
	}
	
	public Contact(Parcel in){
		mDisplayName = in.readString();
		mLookupKey = in.readString();
	}
	
	/**
	 * @return the mDisplayName
	 */
	public String getDisplayName() {
		return mDisplayName;
	}
	/**
	 * @return the mLookupKey
	 */
	public String getLookupKey() {
		return mLookupKey;
	}
	
	public void writeToParcel(Parcel out, int arg1) {
		out.writeString(mDisplayName);
		out.writeString(mLookupKey);
	}
	
	// this is used to regenerate your object. All Parcelables must have a CREATOR that implements these two methods
    public static final Parcelable.Creator<Contact> CREATOR = new Parcelable.Creator<Contact>() {
        public Contact createFromParcel(Parcel in) {
            return new Contact(in);
        }

        public Contact[] newArray(int size) {
            return new Contact[size];
        }
    };


	public int describeContents() {
		return 0;
	}
	
}
